Skip to content

Add Python example for uploading a Checkmarx report - #148

Closed
Ibrahimrahhal wants to merge 3 commits into
mainfrom
cursor/checkmarx-upload-example-5de1
Closed

Add Python example for uploading a Checkmarx report#148
Ibrahimrahhal wants to merge 3 commits into
mainfrom
cursor/checkmarx-upload-example-5de1

Conversation

@Ibrahimrahhal

@Ibrahimrahhal Ibrahimrahhal commented Aug 5, 2026

Copy link
Copy Markdown
Member

Summary

Adds examples/upload_checkmarx.py: a small stdlib-only Python script that creates a Corgea scan from a Checkmarx report using the same HTTP API as corgea upload.

export CORGEA_TOKEN=<token>
./upload_checkmarx.py <code_path> <report_path>
  • Takes the scanned source tree and the Checkmarx report (CxXMLResults XML, CLI JSON, or web JSON)
  • Uploads referenced source files, then the report (engine=checkmarx)
  • Prints the scan URL and exits — does not wait for completion
  • No third-party deps

Includes a runnable fixture under examples/checkmarx/ and a short README.

Test plan

  • Ran against a local mock of /api/v1/{verify,code-upload,scan-upload} — verify → code-upload (per file) → scan-upload with engine=checkmarx, no wait/poll
  • Spot-check against a real Corgea token with a real Checkmarx export
Open in Web Open in Cursor 

cursoragent and others added 3 commits August 5, 2026 08:12
A dependency-free Python script for pipelines that cannot run the CLI
binary, plus a runnable CxXMLResults fixture and the sources it points at.

Co-authored-by: Ibrahim Rahhal <ibrahim.rahhal3636@gmail.com>
Replace the elaborate Python helper with upload_checkmarx.sh that takes
<code_path> <report_path>, creates the scan, and exits without waiting.

Co-authored-by: Ibrahim Rahhal <ibrahim.rahhal3636@gmail.com>
Two args: code_path and report_path. Creates the scan and exits without
waiting. Stdlib only.

Co-authored-by: Ibrahim Rahhal <ibrahim.rahhal3636@gmail.com>
@cursor cursor Bot changed the title Add bash example for uploading a Checkmarx report Add Python example for uploading a Checkmarx report Aug 5, 2026
@Ibrahimrahhal
Ibrahimrahhal deleted the cursor/checkmarx-upload-example-5de1 branch August 5, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants